package ioperations;

import book.Book;
import book.BookList;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 姚东名
 * Date: 2024-06-01
 * Time: 23:58
 */
public class ShowOperation implements Ioperation {
    @Override
    public void work(BookList bookList) {
        System.out.println("展示图书");
        int currentSize = bookList.getUsedSize();
        for (int i = 0; i < currentSize; i++) {
            Book book = bookList.getBooks(i);
            //展示图书：
            System.out.println(book);
        }
    }
}
